package messages;


/**
 * InvitationReplyMessage
 *
 * This is the message clients send when replying to invitation messages.
 */
public class InvitationReplyMessage extends Message {

	public InvitationReplyMessage(int replyId, boolean accepted) {
		super();
		
		this.replyId = replyId;
		this.accepted = accepted;
	}

	
	/**
	 * Returns an invitation identifier the destiny must include in the reply message.
	 * 
	 * @return An invitation identifier the destiny must include in the reply message.
	 */
	public int getReplyId() {
		return this.replyId;
	}


	/**
	 * Was the invitation accepted?
	 * 
	 * @return True if the destiny accepted the invitation, false otherwise
	 */
	public boolean isAccepted() {
		return this.accepted;
	}
	
	
	private boolean accepted;	// Was the invitation accepted?
	private int replyId;		// An invitation identifier assigned by the Controller that
								// the destiny must include in the reply message.

	private static final long serialVersionUID = 1L;	
}
